package cn.ynu.cmrs.model;

import java.io.Serializable;
import java.util.Arrays;

/**
 * Course detail unit<br>
 * 
 * <br>
 * <table>
 * <tr><td><b>field</b></td><td><b>description</b></td><td><b>example</b></td></tr>
 * <tr><td>id</td><td>id of the course</td><td>"2009106001"</td></tr>
 * <tr><td>name</td><td>name of the course</td><td>"Computer network"</td></tr>
 * <tr><td>icon</td><td>subUrl of course icon</td><td>"/images/course_icon/2009106001.png"</td></tr>
 * <tr><td>teacher</td><td>name of the teacher</td><td>"Bill Gates"</td></tr>
 * <tr><td>collegename</td><td>name of school</td><td>"Information school"</td></tr>
 * <tr><td>collegeid</td><td>id of the school</td><td>"0001"</td></tr>
 * <tr><td>mark</td><td>score of the course</td><td>8</td></tr>
 * <tr><td>video</td><td>videos of the course</td><td>["/videos/2009106001_0.mp4", "/videos/2009106001_1.mp4"]</td></tr>
 * <tr><td>length</td><td>length of the video</td><td>"two chapter, 1h45m23s"</td></tr>
 * <tr><td>address</td><td>address of the classroom</td><td>"GeWu building 1218"</td></tr>
 * <tr><td>latitude</td><td>latitude of the classroom</td><td>"23.234512"</td></tr>
 * <tr><td>longitude</td><td>longitude of the classroom</td><td>"123.234512"</td></tr>
 * <tr><td>information</td><td>simple introduce of the course</td><td>"Computer network is a course"</td></tr>
 * <tr><td>detailInformation</td><td>detail introduce of the course</td><td>"Computer network is not just a course"</td></tr>
 * <tr><td>pictures</td><td>pictures about the course</td><td>["/images/2009106001_0.jpg", "/images/2009106001_1.jpg"]</td></tr>
 * <tr><td>status</td><td>Result state of get json string from the server</td><td>"{\"status\":2000, \"message\":\"connect error, please check the network\"}"</td></tr>
 * </table>
 * 
 * @author starsfury
 *
 */
public class CourseDetail implements Serializable{

	private static final long serialVersionUID = 3776822153233561863L;
	private String id = "";
	private String name = "";
	private String icon = "";
	private String teacher = "";
	private String collegename = "";
	private String collegeid = "";
	private int mark = 0;
	private String[] video = {};
	private String length = "";
	private String address = "";
	private String latitude = "";
	private String longitude = "";
	private String information = "";
	private String detailInformation = "";
	private String[] pictures = {};
	private String[] status = {};
	
	public CourseDetail() {
		super();
		// TODO Auto-generated constructor stub
	}

	public CourseDetail(String id, String name, String icon, String teacher,
			String collegename, String collegeid, int mark, String[] video,
			String length, String address, String latitude, String longitude,
			String information, String detailInformation, String[] pictures,
			String[] status) {
		super();
		this.id = id;
		this.name = name;
		this.icon = icon;
		this.teacher = teacher;
		this.collegename = collegename;
		this.collegeid = collegeid;
		this.mark = mark;
		this.video = video;
		this.length = length;
		this.address = address;
		this.latitude = latitude;
		this.longitude = longitude;
		this.information = information;
		this.detailInformation = detailInformation;
		this.pictures = pictures;
		this.status = status;
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getIcon() {
		return icon;
	}

	public void setIcon(String icon) {
		this.icon = icon;
	}

	public String getTeacher() {
		return teacher;
	}

	public void setTeacher(String teacher) {
		this.teacher = teacher;
	}

	public String getCollegename() {
		return collegename;
	}

	public void setCollegename(String collegename) {
		this.collegename = collegename;
	}

	public String getCollegeid() {
		return collegeid;
	}

	public void setCollegeid(String collegeid) {
		this.collegeid = collegeid;
	}

	public int getMark() {
		return mark;
	}

	public void setMark(int mark) {
		this.mark = mark;
	}

	public String[] getVideo() {
		return video;
	}

	public void setVideo(String[] video) {
		this.video = video;
	}

	public String getLength() {
		return length;
	}

	public void setLength(String length) {
		this.length = length;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getLatitude() {
		return latitude;
	}

	public void setLatitude(String latitude) {
		this.latitude = latitude;
	}

	public String getLongitude() {
		return longitude;
	}

	public void setLongitude(String longitude) {
		this.longitude = longitude;
	}

	public String getInformation() {
		return information;
	}

	public void setInformation(String information) {
		this.information = information;
	}

	public String getDetailInformation() {
		return detailInformation;
	}

	public void setDetailInformation(String detailInformation) {
		this.detailInformation = detailInformation;
	}

	public String[] getPictures() {
		return pictures;
	}

	public void setPictures(String[] pictures) {
		this.pictures = pictures;
	}

	public String[] getStatus() {
		return status;
	}

	public void setStatus(String[] status) {
		this.status = status;
	}

	@Override
	public String toString() {
		return "CourseDetail [id=" + id + ", name=" + name + ", icon=" + icon
				+ ", teacher=" + teacher + ", collegename=" + collegename
				+ ", collegeid=" + collegeid + ", mark=" + mark + ", video="
				+ Arrays.toString(video) + ", length=" + length + ", address="
				+ address + ", latitude=" + latitude + ", longitude="
				+ longitude + ", information=" + information
				+ ", detailInformation=" + detailInformation + ", pictures="
				+ Arrays.toString(pictures) + ", status="
				+ Arrays.toString(status) + "]";
	}
	
}
